package com.yearner.reviewplan.user.commands;

import lombok.Getter;
import lombok.Setter;

/**
 * @author pengyg
 * @since 2019/10/18
 */
@Getter
@Setter
public class ChangePasswordCommand {
    private String userId;
    private String newPassword;
    private String oldPassword;
    private ChangePasswordCommand(){}

    public static ChangePasswordCommand create(String id, String password) {
        ChangePasswordCommand command = new ChangePasswordCommand();
        command.setUserId(id);
        command.setNewPassword(password);
        return command;
    }
}
